// 第二章代码
#include <stdio.h>

int main() {
    puts("[ 点菜系统 ]\n");

    int money = 0;
    int c;

    do {
        puts("1. [￥28] 干炸里脊");
        puts("2. [￥32] 香菇炖鸡");
        puts("3. [￥12] 凉拌黄瓜");
        puts("4. [￥14] 家常土豆丝");
        puts("5. [￥6 ] 啤酒");

        puts("\n0. 点完了");
        printf("请点菜: ");

        scanf("%d", &c);
        switch (c) {
        case 1:
            money += 28;
            break;
        case 2:
            money += 32;
            break;
        case 3:
            money += 12;
            break;
        case 4:
            money += 14;
            break;
        case 5:
            money += 6;
            break;
        }
    } while (c != 0);

    printf("总金额: %d\n", money);


    return 0;
}
